﻿@using IterationLife.Extensions.EasyUI.GridColumns
@using Util.Ui
@model IterationLife.PlatformBackEnd.AppServices.Dtos.FootballTeachings.CourseCategoryDto
@{
    var x = @Html.EasyUi();
}
@section head {
    <script type="text/javascript">
        $(function () {
            $.easyui.deleteUrl = "/FootballTeachings/courseCategory/delete";
        });
    </script>
}
@section top {
    @*工具栏*@
    <div class="toolbar">
        @x.DialogButton( "添加课程分类", "/FootballTeachings/courseCategory/add").Icon( "icon-add" ).Plain().DialogSize(420,300)
        @x.DialogButton( "编辑课程分类", "/FootballTeachings/courseCategory/edit").Id( "btnEdit" ).Icon( "icon-edit" ).Plain().ShowEditDialog().DialogSize(420, 300)
        @x.Button( "删除课程分类" ).Icon( "icon-delete" ).Plain().Delete()
        @x.DialogButton( "查看详细", "/FootballTeachings/courseCategory/detail").Id( "btnLook" ).Icon( "icon-look" ).Plain().ShowDetailDialog().DialogSize(470, 300)
        @x.Button( "刷 新" ).Icon( "icon-refresh" ).Plain().Refresh()
    </div>
}
@section content {
    @*右键菜单*@
    @Html.Partial( "Menus/FormMenu" )
    @*查询表单*@
    @Html.Partial( "Parts/QueryForm" )
    @*表格*@
    @(x.Grid( "grid" ).Sort("SortId", false).Toolbar( "divQuery" ).Url("/FootballTeachings/CourseCategory/PagerQuery")
        .ShowEditDialogByDblClick().Menu().FitColumns().Fit()
        .Columns(
            x.GridColumn( t => t.Id ).CheckBox(),
            x.GridColumn(t => t.Code, 100).FormatByEnabled(),
            x.GridColumn( t => t.Name,100 ),
            x.GridColumn( t => t.Banner,100 ).AttachmentPreview(),
            x.GridColumn( t => t.SortId,100 ),
            x.GridColumn( t => t.CreationTime,120 )
        )
    )
}